<!doctype html>


<html>
<head>
  <link rel="shortcut icon" href="static/images/favicon.ico" type="image/x-icon">
  <title>events.js (Closure Library API Documentation - JavaScript)</title>
  <link rel="stylesheet" href="static/css/base.css">
  <link rel="stylesheet" href="static/css/doc.css">
  <link rel="stylesheet" href="static/css/sidetree.css">
  <link rel="stylesheet" href="static/css/prettify.css">

  <script>
     var _staticFilePath = "static/";
  </script>

  <script src="static/js/doc.js">
  </script>

  <meta charset="utf8">
</head>

<body onload="prettyPrint()">

<div id="header">
  <div class="g-section g-tpl-50-50 g-split">
    <div class="g-unit g-first">
      <a id="logo" href="index.html">Closure Library API Documentation</a>
    </div>

    <div class="g-unit">
      <div class="g-c">
        <strong>Go to class or file:</strong>
        <input type="text" id="ac">
      </div>
    </div>
  </div>
</div>





<div class="colmask rightmenu">
<div class="colleft">
    <div class="col1">
      <!-- Column 1 start -->

<div id="title">
       <span class="fn">events.js</span>
</div>

<div class="g-section g-tpl-75-25">
  <div class="g-unit g-first" id="description">
    Event Manager.

 Provides an abstracted interface to the browsers&#39; event
 systems. This uses an indirect lookup of listener functions to avoid circular
 references between DOM (in IE) or XPCOM (in Mozilla) objects which leak
 memory. This makes it easier to write OO Javascript/DOM code.

 It simulates capture &amp; bubble in Internet Explorer.

 The listeners will also automagically have their event objects patched, so
 your handlers don&#39;t need to worry about the browser.

 Example usage:
 <pre class="lang-js">
 goog.events.listen(myNode, &#39;click&#39;, function(e) { alert(&#39;woo&#39;) });
 goog.events.listen(myNode, &#39;mouseover&#39;, mouseHandler, true);
 goog.events.unlisten(myNode, &#39;mouseover&#39;, mouseHandler, true);
 goog.events.removeAll(myNode);
 goog.events.removeAll();
 </pre>

 in IE and event object patching]
  </div>
  

        <div class="g-unit" id="useful-links">
          <div class="title">Useful links</div>
          <ol>
            <li><a href="../demos/events.html">Demo</a></li>
            <li><a href="../demos/event-propogation.html">Demo</a></li>
            <li><a href="closure_goog_events_events.js.source.html"><span class='source-code-link'>Source Code</span></a></li>
          </ol>
        </div>
</div>

<h2 class="g-first">File Location</h2>
  <div class="g-section g-tpl-20-80">
    <div class="g-unit g-first">
      <div class="g-c-cell code-label">events/events.js</div>
    </div>
  </div>
<hr/>


   
<br/>

  <div class="legend">
        <span class="key publickey"></span><span>Public</span>
        <span class="key protectedkey"></span><span>Protected</span>
        <span class="key privatekey"></span><span>Private</span>
  </div>


  <h2>Global Functions</h2>





<div class="section">
  <table class="horiz-rule">


     <tr class="even entry private">
       <td class="access"></td>






  <td>
    <a name="goog.events.cleanUp_"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">cleanUp_<span class="args">(<span class="arg">type</span>,&nbsp;<span class="arg">capture</span>,&nbsp;<span class="arg">srcHashCode</span>,&nbsp;<span class="arg">listenerArray</span>)</span>
        </span>
      </div>


     <div class="entryOverview">
       Cleans up the listener array as well as the listener tree
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">type</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span></div>
        <div class="entryOverview">The type of the event.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">capture</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
        <div class="entryOverview">Whether to clean up capture phase listeners instead bubble phase listeners.</div>
     </td>
   </tr>
     
   <tr class="even">
     <td>
        <span class="entryName">srcHashCode</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Number">number</a></span></div>
        <div class="entryOverview">The hash code of the source.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">listenerArray</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Array">Array</a></span>.&lt;<span class="type"><a href="class_goog_events_Listener.html">goog.events.Listener</a></span>&gt;</div>
        <div class="entryOverview">The array being cleaned.</div>
     </td>
   </tr>
  </table>
      </div>
   
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line411">code &raquo;</a>
  </td>
     </tr>


     <tr class="odd entry public">
       <td class="access"></td>






  <td>
    <a name="goog.events.dispatchEvent"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">dispatchEvent<span class="args">(<span class="arg">src</span>,&nbsp;<span class="arg">e</span>)</span>
        </span>
        &#8658; <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
      </div>


     <div class="entryOverview">
       Dispatches an event (or event like object) and calls all listeners
listening for events of this type. The type of the event is decided by the
type property on the event object.

If any of the listeners returns false OR calls preventDefault then this
function will return false.  If one of the capture listeners calls
stopPropagation, then the bubble listeners won&#39;t fire.
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">src</span>
        : <div class="fullType"><span class="type"><a href="class_goog_events_EventTarget.html">goog.events.EventTarget</a></span></div>
        <div class="entryOverview">The event target.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">e</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span><span>&nbsp;|&nbsp;</span><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span><span>&nbsp;|&nbsp;</span><span class="type"><a href="class_goog_events_Event.html">goog.events.Event</a></span></div>
        <div class="entryOverview">Event object.</div>
     </td>
   </tr>
  </table>
      </div>
   
      <div class="detailsSection">
        <b>Returns:</b>&nbsp;<div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>&nbsp;
            If anyone called preventDefault on the event object (or if any of the handlers returns false) this will also return false. If there are no handlers, or if all handlers return true, this returns true.
      </div>
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line827">code &raquo;</a>
  </td>
     </tr>


     <tr class="even entry public">
       <td class="access"></td>






  <td>
    <a name="goog.events.expose"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">expose<span class="args">(<span class="arg">e</span>)</span>
        </span>
        &#8658; <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span></div>
      </div>


     <div class="entryOverview">
       Provides a nice string showing the normalized event objects public members
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">e</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">Event Object.</div>
     </td>
   </tr>
  </table>
      </div>
   
      <div class="detailsSection">
        <b>Returns:</b>&nbsp;<div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span></div>&nbsp;
            String of the public members of the normalized event object.
      </div>
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line636">code &raquo;</a>
  </td>
     </tr>


     <tr class="odd entry public">
       <td class="access"></td>






  <td>
    <a name="goog.events.fireListener"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">fireListener<span class="args">(<span class="arg">listener</span>,&nbsp;<span class="arg">eventObject</span>)</span>
        </span>
        &#8658; <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
      </div>


     <div class="entryOverview">
       Fires a listener with a set of arguments
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">listener</span>
        : <div class="fullType"><span class="type"><a href="class_goog_events_Listener.html">goog.events.Listener</a></span></div>
        <div class="entryOverview">The listener object to call.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">eventObject</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">The event object to pass to the listener.</div>
     </td>
   </tr>
  </table>
      </div>
   
      <div class="detailsSection">
        <b>Returns:</b>&nbsp;<div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>&nbsp;
            Result of listener.
      </div>
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line793">code &raquo;</a>
  </td>
     </tr>


     <tr class="even entry public">
       <td class="access"></td>






  <td>
    <a name="goog.events.fireListeners"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">fireListeners<span class="args">(<span class="arg">obj</span>,&nbsp;<span class="arg">type</span>,&nbsp;<span class="arg">capture</span>,&nbsp;<span class="arg">eventObject</span>)</span>
        </span>
        &#8658; <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
      </div>


     <div class="entryOverview">
       Fires an object&#39;s listeners of a particular type and phase
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">obj</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">Object whose listeners to call.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">type</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span></div>
        <div class="entryOverview">Event type.</div>
     </td>
   </tr>
     
   <tr class="even">
     <td>
        <span class="entryName">capture</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
        <div class="entryOverview">Which event phase.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">eventObject</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">Event object to be passed to listener.</div>
     </td>
   </tr>
  </table>
      </div>
   
      <div class="detailsSection">
        <b>Returns:</b>&nbsp;<div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>&nbsp;
            True if all listeners returned true else false.
      </div>
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line724">code &raquo;</a>
  </td>
     </tr>


     <tr class="odd entry private">
       <td class="access"></td>






  <td>
    <a name="goog.events.fireListeners_"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">fireListeners_<span class="args">(<span class="arg">map</span>,&nbsp;<span class="arg">obj</span>,&nbsp;<span class="arg">type</span>,&nbsp;<span class="arg">capture</span>,&nbsp;<span class="arg">eventObject</span>)</span>
        </span>
        &#8658; <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
      </div>


     <div class="entryOverview">
       Fires an object&#39;s listeners of a particular type and phase.
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">map</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">Object with listeners in it.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">obj</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">Object whose listeners to call.</div>
     </td>
   </tr>
     
   <tr class="even">
     <td>
        <span class="entryName">type</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span></div>
        <div class="entryOverview">Event type.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">capture</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
        <div class="entryOverview">Which event phase.</div>
     </td>
   </tr>
     
   <tr class="even">
     <td>
        <span class="entryName">eventObject</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">Event object to be passed to listener.</div>
     </td>
   </tr>
  </table>
      </div>
   
      <div class="detailsSection">
        <b>Returns:</b>&nbsp;<div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>&nbsp;
            True if all listeners returned true else false.
      </div>
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line748">code &raquo;</a>
  </td>
     </tr>


     <tr class="even entry public">
       <td class="access"></td>






  <td>
    <a name="goog.events.getListener"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">getListener<span class="args">(<span class="arg">src</span>,&nbsp;<span class="arg">type</span>,&nbsp;<span class="arg">listener</span>,&nbsp;<span class="arg">opt_capt</span>,&nbsp;<span class="arg">opt_handler</span>)</span>
        </span>
        &#8658; <div class="fullType"><span>?</span><span class="type"><a href="class_goog_events_Listener.html">goog.events.Listener</a></span></div>
      </div>


     <div class="entryOverview">
       Gets the goog.events.Listener for the event or null if no such listener is
in use.
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">src</span>
        : <div class="fullType"><span class="type">EventTarget</span><span>&nbsp;|&nbsp;</span><span class="type"><a href="class_goog_events_EventTarget.html">goog.events.EventTarget</a></span></div>
        <div class="entryOverview">The node to stop listening to events on.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">type</span>
        : <div class="fullType"><span>?</span><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span></div>
        <div class="entryOverview">The name of the event without the &#39;on&#39; prefix.</div>
     </td>
   </tr>
     
   <tr class="even">
     <td>
        <span class="entryName">listener</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Function">Function</a></span><span>&nbsp;|&nbsp;</span><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">The listener function to remove.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">opt_capt</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
        <div class="entryOverview">In DOM-compliant browsers, this determines whether the listener is fired during the capture or bubble phase of the event.</div>
     </td>
   </tr>
     
   <tr class="even">
     <td>
        <span class="entryName">opt_handler</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">Element in whose scope to call the listener.</div>
     </td>
   </tr>
  </table>
      </div>
   
      <div class="detailsSection">
        <b>Returns:</b>&nbsp;<div class="fullType"><span>?</span><span class="type"><a href="class_goog_events_Listener.html">goog.events.Listener</a></span></div>&nbsp;
            the found listener or null if not found.
      </div>
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line572">code &raquo;</a>
  </td>
     </tr>


     <tr class="odd entry public">
       <td class="access"></td>






  <td>
    <a name="goog.events.getListeners"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">getListeners<span class="args">(<span class="arg">obj</span>,&nbsp;<span class="arg">type</span>,&nbsp;<span class="arg">capture</span>)</span>
        </span>
        &#8658; <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Array">Array</a></span>.&lt;<span class="type"><a href="class_goog_events_Listener.html">goog.events.Listener</a></span>&gt;</div>
      </div>


     <div class="entryOverview">
       Gets the listeners for a given object, type and capture phase.
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">obj</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">Object to get listeners for.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">type</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span></div>
        <div class="entryOverview">Event type.</div>
     </td>
   </tr>
     
   <tr class="even">
     <td>
        <span class="entryName">capture</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
        <div class="entryOverview">Capture phase?.</div>
     </td>
   </tr>
  </table>
      </div>
   
      <div class="detailsSection">
        <b>Returns:</b>&nbsp;<div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Array">Array</a></span>.&lt;<span class="type"><a href="class_goog_events_Listener.html">goog.events.Listener</a></span>&gt;</div>&nbsp;
            Array of listener objects.
      </div>
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line526">code &raquo;</a>
  </td>
     </tr>


     <tr class="even entry private">
       <td class="access"></td>






  <td>
    <a name="goog.events.getListeners_"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">getListeners_<span class="args">(<span class="arg">obj</span>,&nbsp;<span class="arg">type</span>,&nbsp;<span class="arg">capture</span>)</span>
        </span>
        &#8658; <div class="fullType"><span>?</span><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Array">Array</a></span>.&lt;<span class="type"><a href="class_goog_events_Listener.html">goog.events.Listener</a></span>&gt;</div>
      </div>


     <div class="entryOverview">
       Gets the listeners for a given object, type and capture phase.
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">obj</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">Object to get listeners for.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">type</span>
        : <div class="fullType"><span>?</span><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span></div>
        <div class="entryOverview">Event type.</div>
     </td>
   </tr>
     
   <tr class="even">
     <td>
        <span class="entryName">capture</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
        <div class="entryOverview">Capture phase?.</div>
     </td>
   </tr>
  </table>
      </div>
   
      <div class="detailsSection">
        <b>Returns:</b>&nbsp;<div class="fullType"><span>?</span><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Array">Array</a></span>.&lt;<span class="type"><a href="class_goog_events_Listener.html">goog.events.Listener</a></span>&gt;</div>&nbsp;
            Array of listener objects. Returns null if object has no lsiteners of that type.
      </div>
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line541">code &raquo;</a>
  </td>
     </tr>


     <tr class="odd entry private">
       <td class="access"></td>






  <td>
    <a name="goog.events.getOnString_"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">getOnString_<span class="args">(<span class="arg">type</span>)</span>
        </span>
        &#8658; <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span></div>
      </div>


     <div class="entryOverview">
       Returns a string wth on prepended to the specified type. This is used for IE
which expects &quot;on&quot; to be prepended. This function caches the string in order
to avoid extra allocations in steady state.
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">type</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span></div>
        <div class="entryOverview">Event type strng.</div>
     </td>
   </tr>
  </table>
      </div>
   
      <div class="detailsSection">
        <b>Returns:</b>&nbsp;<div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span></div>&nbsp;
            The type string with &#39;on&#39; prepended.
      </div>
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line707">code &raquo;</a>
  </td>
     </tr>


     <tr class="even entry public">
       <td class="access"></td>






  <td>
    <a name="goog.events.getTotalListenerCount"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">getTotalListenerCount<span class="args">()</span>
        </span>
        &#8658; <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Number">number</a></span></div>
      </div>


     <div class="entryOverview">
       Gets the total number of listeners currently in the system.
     </div>


    <! -- Method details -->
    <div class="entryDetails">

   
      <div class="detailsSection">
        <b>Returns:</b>&nbsp;<div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Number">number</a></span></div>&nbsp;
            Number of listeners.
      </div>
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line806">code &raquo;</a>
  </td>
     </tr>


     <tr class="odd entry public">
       <td class="access"></td>






  <td>
    <a name="goog.events.getUniqueId"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">getUniqueId<span class="args">(<span class="arg">identifier</span>)</span>
        </span>
        &#8658; <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span></div>
      </div>


     <div class="entryOverview">
       Creates a unique event id.
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">identifier</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span></div>
        <div class="entryOverview">The identifier.</div>
     </td>
   </tr>
  </table>
      </div>
   
      <div class="detailsSection">
        <b>Returns:</b>&nbsp;<div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span></div>&nbsp;
            A unique identifier.
      </div>
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line1109">code &raquo;</a>
  </td>
     </tr>


     <tr class="even entry public">
       <td class="access"></td>






  <td>
    <a name="goog.events.handleBrowserEvent_"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">handleBrowserEvent_<span class="args">()</span>
        </span>
      </div>


     <div class="entryOverview">
       <span class='nodesc'>No description.</span>
     </div>

   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line920">code &raquo;</a>
  </td>
     </tr>


     <tr class="odd entry public">
       <td class="access"></td>






  <td>
    <a name="goog.events.hasListener"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">hasListener<span class="args">(<span class="arg">obj</span>,&nbsp;<span class="arg">opt_type</span>,&nbsp;<span class="arg">opt_capture</span>)</span>
        </span>
        &#8658; <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
      </div>


     <div class="entryOverview">
       Returns whether an event target has any active listeners matching the
specified signature. If either the type or capture parameters are
unspecified, the function will match on the remaining criteria.
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">obj</span>
        : <div class="fullType"><span class="type">EventTarget</span><span>&nbsp;|&nbsp;</span><span class="type"><a href="class_goog_events_EventTarget.html">goog.events.EventTarget</a></span></div>
        <div class="entryOverview">Target to get listeners for.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">opt_type</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span></div>
        <div class="entryOverview">Event type.</div>
     </td>
   </tr>
     
   <tr class="even">
     <td>
        <span class="entryName">opt_capture</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
        <div class="entryOverview">Whether to check for capture or bubble-phase listeners.</div>
     </td>
   </tr>
  </table>
      </div>
   
      <div class="detailsSection">
        <b>Returns:</b>&nbsp;<div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>&nbsp;
            Whether an event target has one or more listeners matching the requested type and/or capture phase.
      </div>
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line601">code &raquo;</a>
  </td>
     </tr>


     <tr class="even entry private">
       <td class="access"></td>






  <td>
    <a name="goog.events.isMarkedIeEvent_"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">isMarkedIeEvent_<span class="args">(<span class="arg">e</span>)</span>
        </span>
        &#8658; <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
      </div>


     <div class="entryOverview">
       This is used to check if an IE event has already been handled by the Closure
system so we do not do the Closure pass twice for a bubbling event.
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">e</span>
        : <div class="fullType"><span class="type">Event</span></div>
        <div class="entryOverview">The IE browser event.</div>
     </td>
   </tr>
  </table>
      </div>
   
      <div class="detailsSection">
        <b>Returns:</b>&nbsp;<div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>&nbsp;
            True if the event object has been marked.
      </div>
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line1090">code &raquo;</a>
  </td>
     </tr>


     <tr class="odd entry public">
       <td class="access"></td>






  <td>
    <a name="goog.events.listen"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">listen<span class="args">(<span class="arg">src</span>,&nbsp;<span class="arg">type</span>,&nbsp;<span class="arg">listener</span>,&nbsp;<span class="arg">opt_capt</span>,&nbsp;<span class="arg">opt_handler</span>)</span>
        </span>
        &#8658; <div class="fullType"><span>?</span><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Number">number</a></span></div>
      </div>


     <div class="entryOverview">
       Adds an event listener for a specific event on a DOM Node or an object that
has implemented {@link goog.events.EventTarget}. A listener can only be
added once to an object and if it is added again the key for the listener
is returned.
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">src</span>
        : <div class="fullType"><span class="type">EventTarget</span><span>&nbsp;|&nbsp;</span><span class="type"><a href="class_goog_events_EventTarget.html">goog.events.EventTarget</a></span></div>
        <div class="entryOverview">The node to listen to events on.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">type</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span><span>&nbsp;|&nbsp;</span><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Array">Array</a></span>.&lt;<span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span>&gt;</div>
        <div class="entryOverview">Event type or array of event types.</div>
     </td>
   </tr>
     
   <tr class="even">
     <td>
        <span class="entryName">listener</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Function">Function</a></span><span>&nbsp;|&nbsp;</span><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">Callback method, or an object with a handleEvent function.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">opt_capt</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
        <div class="entryOverview">Whether to fire in capture phase (defaults to false).</div>
     </td>
   </tr>
     
   <tr class="even">
     <td>
        <span class="entryName">opt_handler</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">Element in whose scope to call the listener.</div>
     </td>
   </tr>
  </table>
      </div>
   
      <div class="detailsSection">
        <b>Returns:</b>&nbsp;<div class="fullType"><span>?</span><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Number">number</a></span></div>&nbsp;
            Unique key for the listener.
      </div>
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line135">code &raquo;</a>
  </td>
     </tr>


     <tr class="even entry public">
       <td class="access"></td>






  <td>
    <a name="goog.events.listenOnce"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">listenOnce<span class="args">(<span class="arg">src</span>,&nbsp;<span class="arg">type</span>,&nbsp;<span class="arg">listener</span>,&nbsp;<span class="arg">opt_capt</span>,&nbsp;<span class="arg">opt_handler</span>)</span>
        </span>
        &#8658; <div class="fullType"><span>?</span><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Number">number</a></span></div>
      </div>


     <div class="entryOverview">
       Adds an event listener for a specific event on a DomNode or an object that
has implemented {@link goog.events.EventTarget}. After the event has fired
the event listener is removed from the target.
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">src</span>
        : <div class="fullType"><span class="type">EventTarget</span><span>&nbsp;|&nbsp;</span><span class="type"><a href="class_goog_events_EventTarget.html">goog.events.EventTarget</a></span></div>
        <div class="entryOverview">The node to listen to events on.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">type</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span><span>&nbsp;|&nbsp;</span><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Array">Array</a></span>.&lt;<span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span>&gt;</div>
        <div class="entryOverview">Event type or array of event types.</div>
     </td>
   </tr>
     
   <tr class="even">
     <td>
        <span class="entryName">listener</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Function">Function</a></span><span>&nbsp;|&nbsp;</span><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">Callback method.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">opt_capt</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
        <div class="entryOverview">Fire in capture phase?.</div>
     </td>
   </tr>
     
   <tr class="even">
     <td>
        <span class="entryName">opt_handler</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">Element in whose scope to call the listener.</div>
     </td>
   </tr>
  </table>
      </div>
   
      <div class="detailsSection">
        <b>Returns:</b>&nbsp;<div class="fullType"><span>?</span><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Number">number</a></span></div>&nbsp;
            Unique key for the listener.
      </div>
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line244">code &raquo;</a>
  </td>
     </tr>


     <tr class="odd entry public">
       <td class="access"></td>






  <td>
    <a name="goog.events.listenWithWrapper"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">listenWithWrapper<span class="args">(<span class="arg">src</span>,&nbsp;<span class="arg">wrapper</span>,&nbsp;<span class="arg">listener</span>,&nbsp;<span class="arg">opt_capt</span>,&nbsp;<span class="arg">opt_handler</span>)</span>
        </span>
      </div>


     <div class="entryOverview">
       Adds an event listener with a specific event wrapper on a DOM Node or an
object that has implemented {@link goog.events.EventTarget}. A listener can
only be added once to an object.
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">src</span>
        : <div class="fullType"><span class="type">EventTarget</span><span>&nbsp;|&nbsp;</span><span class="type"><a href="class_goog_events_EventTarget.html">goog.events.EventTarget</a></span></div>
        <div class="entryOverview">The node to listen to events on.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">wrapper</span>
        : <div class="fullType"><span class="type">goog.events.EventWrapper</span></div>
        <div class="entryOverview">Event wrapper to use.</div>
     </td>
   </tr>
     
   <tr class="even">
     <td>
        <span class="entryName">listener</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Function">Function</a></span><span>&nbsp;|&nbsp;</span><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">Callback method, or an object with a handleEvent function.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">opt_capt</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
        <div class="entryOverview">Whether to fire in capture phase (defaults to false).</div>
     </td>
   </tr>
     
   <tr class="even">
     <td>
        <span class="entryName">opt_handler</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">Element in whose scope to call the listener.</div>
     </td>
   </tr>
  </table>
      </div>
   
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line273">code &raquo;</a>
  </td>
     </tr>


     <tr class="even entry private">
       <td class="access"></td>






  <td>
    <a name="goog.events.markIeEvent_"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">markIeEvent_<span class="args">(<span class="arg">e</span>)</span>
        </span>
      </div>


     <div class="entryOverview">
       This is used to mark the IE event object so we do not do the Closure pass
twice for a bubbling event.
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">e</span>
        : <div class="fullType"><span class="type">Event</span></div>
        <div class="entryOverview">The IE browser event.</div>
     </td>
   </tr>
  </table>
      </div>
   
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line1050">code &raquo;</a>
  </td>
     </tr>


     <tr class="odd entry public">
       <td class="access"></td>






  <td>
    <a name="goog.events.protectBrowserEventEntryPoint"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">protectBrowserEventEntryPoint<span class="args">(<span class="arg">errorHandler</span>,&nbsp;<span class="arg">opt_tracers</span>)</span>
        </span>
      </div>


     <div class="entryOverview">
       Installs exception protection for the browser event entry point using the
given error handler.
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">errorHandler</span>
        : <div class="fullType"><span class="type"><a href="class_goog_debug_ErrorHandler.html">goog.debug.ErrorHandler</a></span></div>
        <div class="entryOverview">Error handler with which to protect the entry point.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">opt_tracers</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
        <div class="entryOverview">Whether to install tracers around the browser event entry point.</div>
     </td>
   </tr>
  </table>
      </div>
   
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line918">code &raquo;</a>
  </td>
     </tr>


     <tr class="even entry public">
       <td class="access"></td>






  <td>
    <a name="goog.events.removeAll"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">removeAll<span class="args">(<span class="arg">opt_obj</span>,&nbsp;<span class="arg">opt_type</span>,&nbsp;<span class="arg">opt_capt</span>)</span>
        </span>
        &#8658; <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Number">number</a></span></div>
      </div>


     <div class="entryOverview">
       Removes all listeners from an object, if no object is specified it will
remove all listeners that have been registered.  You can also optionally
remove listeners of a particular type or capture phase.
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">opt_obj</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">Object to remove listeners from.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">opt_type</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span></div>
        <div class="entryOverview">Type of event to, default is all types.</div>
     </td>
   </tr>
     
   <tr class="even">
     <td>
        <span class="entryName">opt_capt</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
        <div class="entryOverview">Whether to remove the listeners from the capture or bubble phase.  If unspecified, will remove both.</div>
     </td>
   </tr>
  </table>
      </div>
   
      <div class="detailsSection">
        <b>Returns:</b>&nbsp;<div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Number">number</a></span></div>&nbsp;
            Number of listeners removed.
      </div>
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line478">code &raquo;</a>
  </td>
     </tr>


     <tr class="odd entry public">
       <td class="access"></td>






  <td>
    <a name="goog.events.unlisten"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">unlisten<span class="args">(<span class="arg">src</span>,&nbsp;<span class="arg">type</span>,&nbsp;<span class="arg">listener</span>,&nbsp;<span class="arg">opt_capt</span>,&nbsp;<span class="arg">opt_handler</span>)</span>
        </span>
        &#8658; <div class="fullType"><span>?</span><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
      </div>


     <div class="entryOverview">
       Removes an event listener which was added with listen().
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">src</span>
        : <div class="fullType"><span class="type">EventTarget</span><span>&nbsp;|&nbsp;</span><span class="type"><a href="class_goog_events_EventTarget.html">goog.events.EventTarget</a></span></div>
        <div class="entryOverview">The target to stop listening to events on.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">type</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span><span>&nbsp;|&nbsp;</span><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Array">Array</a></span>.&lt;<span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span>&gt;</div>
        <div class="entryOverview">The name of the event without the &#39;on&#39; prefix.</div>
     </td>
   </tr>
     
   <tr class="even">
     <td>
        <span class="entryName">listener</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Function">Function</a></span><span>&nbsp;|&nbsp;</span><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">The listener function to remove.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">opt_capt</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
        <div class="entryOverview">In DOM-compliant browsers, this determines whether the listener is fired during the capture or bubble phase of the event.</div>
     </td>
   </tr>
     
   <tr class="even">
     <td>
        <span class="entryName">opt_handler</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">Element in whose scope to call the listener.</div>
     </td>
   </tr>
  </table>
      </div>
   
      <div class="detailsSection">
        <b>Returns:</b>&nbsp;<div class="fullType"><span>?</span><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>&nbsp;
            indicating whether the listener was there to remove.
      </div>
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line293">code &raquo;</a>
  </td>
     </tr>


     <tr class="even entry public">
       <td class="access"></td>






  <td>
    <a name="goog.events.unlistenByKey"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">unlistenByKey<span class="args">(<span class="arg">key</span>)</span>
        </span>
        &#8658; <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
      </div>


     <div class="entryOverview">
       Removes an event listener which was added with listen() by the key
returned by listen().
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">key</span>
        : <div class="fullType"><span>?</span><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Number">number</a></span></div>
        <div class="entryOverview">The key returned by listen() for this event listener.</div>
     </td>
   </tr>
  </table>
      </div>
   
      <div class="detailsSection">
        <b>Returns:</b>&nbsp;<div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>&nbsp;
            indicating whether the listener was there to remove.
      </div>
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line327">code &raquo;</a>
  </td>
     </tr>


     <tr class="odd entry public">
       <td class="access"></td>






  <td>
    <a name="goog.events.unlistenWithWrapper"></a>


     <div class="arg">
       <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">unlistenWithWrapper<span class="args">(<span class="arg">src</span>,&nbsp;<span class="arg">wrapper</span>,&nbsp;<span class="arg">listener</span>,&nbsp;<span class="arg">opt_capt</span>,&nbsp;<span class="arg">opt_handler</span>)</span>
        </span>
      </div>


     <div class="entryOverview">
       Removes an event listener which was added with listenWithWrapper().
     </div>


    <! -- Method details -->
    <div class="entryDetails">

      <div class="detailsSection">
        <b>Arguments: </b>






<table class="horiz-rule">
     
   <tr class="even">
     <td>
        <span class="entryName">src</span>
        : <div class="fullType"><span class="type">EventTarget</span><span>&nbsp;|&nbsp;</span><span class="type"><a href="class_goog_events_EventTarget.html">goog.events.EventTarget</a></span></div>
        <div class="entryOverview">The target to stop listening to events on.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">wrapper</span>
        : <div class="fullType"><span class="type">goog.events.EventWrapper</span></div>
        <div class="entryOverview">Event wrapper to use.</div>
     </td>
   </tr>
     
   <tr class="even">
     <td>
        <span class="entryName">listener</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Function">Function</a></span><span>&nbsp;|&nbsp;</span><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">The listener function to remove.</div>
     </td>
   </tr>
     
   <tr class="odd">
     <td>
        <span class="entryName">opt_capt</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Boolean">boolean</a></span></div>
        <div class="entryOverview">In DOM-compliant browsers, this determines whether the listener is fired during the capture or bubble phase of the event.</div>
     </td>
   </tr>
     
   <tr class="even">
     <td>
        <span class="entryName">opt_handler</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
        <div class="entryOverview">Element in whose scope to call the listener.</div>
     </td>
   </tr>
  </table>
      </div>
   
  
    </div>
   
  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line396">code &raquo;</a>
  </td>
     </tr>


  </table>
</div>



  <h2>Global Properties</h2>





<div class="section">
  <table class="horiz-rule">


     <tr class="even entry private">
       <td class="access"></td>





  <a name="goog.events.keySeparator_"></a>

  <td>


     <div class="arg">
        <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">keySeparator_</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span></div>
     </div>


     <div class="entryOverview">
       Separator used to split up the various parts of an event key, to help avoid
the possibilities of collisions.
     </div>

  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line116">Code &raquo;</a>
  </td>
     </tr>


     <tr class="odd entry private">
       <td class="access"></td>





  <a name="goog.events.listenerTree_"></a>

  <td>


     <div class="arg">
        <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">listenerTree_</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
     </div>


     <div class="entryOverview">
       The root of the listener tree
     </div>

  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line82">Code &raquo;</a>
  </td>
     </tr>


     <tr class="even entry private">
       <td class="access"></td>





  <a name="goog.events.listeners_"></a>

  <td>


     <div class="arg">
        <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">listeners_</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span>.&lt;<span class="type"><a href="class_goog_events_Listener.html">goog.events.Listener</a></span>&gt;</div>
     </div>


     <div class="entryOverview">
       Container for storing event listeners and their proxies
     </div>

  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line74">Code &raquo;</a>
  </td>
     </tr>


     <tr class="odd entry private">
       <td class="access"></td>





  <a name="goog.events.onStringMap_"></a>

  <td>


     <div class="arg">
        <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">onStringMap_</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
     </div>


     <div class="entryOverview">
       Map of computed on strings for IE event types. Caching this removes an extra
object allocation in goog.events.listen which improves IE6 performance.
     </div>

  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line108">Code &raquo;</a>
  </td>
     </tr>


     <tr class="even entry private">
       <td class="access"></td>





  <a name="goog.events.onString_"></a>

  <td>


     <div class="arg">
        <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">onString_</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/String">string</a></span></div>
     </div>


     <div class="entryOverview">
       String used to prepend to IE event types.  Not a constant so that it is not
inlined.
     </div>

  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line99">Code &raquo;</a>
  </td>
     </tr>


     <tr class="odd entry private">
       <td class="access"></td>





  <a name="goog.events.sources_"></a>

  <td>


     <div class="arg">
        <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">sources_</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Object">Object</a></span></div>
     </div>


     <div class="entryOverview">
       Lookup for mapping source hash codes to listeners
     </div>

  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line90">Code &raquo;</a>
  </td>
     </tr>


     <tr class="even entry private">
       <td class="access"></td>





  <a name="goog.events.uniqueIdCounter_"></a>

  <td>


     <div class="arg">
        <img align="left" src="static/images/blank.gif">

        <span class="entryNamespace">goog.events.</span><span class="entryName">uniqueIdCounter_</span>
        : <div class="fullType"><span class="type"><a href="http://www.google.com/url?sa=D&q=https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Global_Objects/Number">number</a></span></div>
     </div>


     <div class="entryOverview">
       Counter to create unique event ids.
     </div>

  </td>


  <td class="view-code">
     <a href="closure_goog_events_events.js.source.html#line1100">Code &raquo;</a>
  </td>
     </tr>


  </table>
</div>



      <!-- Column 1 end -->
    </div>

        <div class="col2">
          <!-- Column 2 start -->
          <div class="col2-c">
            <h2 id="ref-head">Directory events</h2>
            <div id="localView"></div>
          </div>

          <div class="col2-c">
            <h2 id="ref-head">File Reference</h2>
            <div id="sideFileIndex" rootPath="closure/goog" current="events/events.js"></div>
          </div>
          <!-- Column 2 end -->
        </div>
</div>
</div>

</body>
</html>
